import type { InjectionKey } from 'vue'
import { IParameterProps, IResponseProps } from "@/store/modules/document/types";

export const documentInjectionKey = Symbol('document') as InjectionKey<string>

export interface IDocumentProps {
  api: string
  method: string
  deprecated: boolean
  consumes: string[]
  operationId: string
  parameters?: IParameterProps[]
  produces: []
  responses: IResponseProps[]
  summary: string
  tags: []
}

export const defaultProps: IDocumentProps = {
  api: '',
  method: '',
  deprecated: false,
  consumes: [],
  operationId: '',
  parameters: [],
  produces: [],
  responses: [],
  summary: '',
  tags: []
}

export type ParameterProps = IParameterProps
export type ResponseProps = IResponseProps